﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class whatis02print : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack) 
        {
            if (Request["c"] != null) 
            {
                string ckbString = Request["c"];
                SetCheckBox(ckbString.Substring(0,1), ckb00);
                SetCheckBox(ckbString.Substring(1, 1), ckb01);
                SetCheckBox(ckbString.Substring(2, 1), ckb02);
                SetCheckBox(ckbString.Substring(3, 1), ckb03);
                SetCheckBox(ckbString.Substring(4, 1), ckb04);
                SetCheckBox(ckbString.Substring(5, 1), ckb05);
                SetCheckBox(ckbString.Substring(6, 1), ckb06);
                SetCheckBox(ckbString.Substring(7, 1), ckb07);
                SetCheckBox(ckbString.Substring(8, 1), ckb08);
                SetCheckBox(ckbString.Substring(9, 1), ckb09);
                SetCheckBox(ckbString.Substring(10, 1), ckb10);
                SetCheckBox(ckbString.Substring(11, 1), ckb11);
                SetCheckBox(ckbString.Substring(12, 1), ckb12);
                SetCheckBox(ckbString.Substring(13, 1), ckb13);
              
                
            }
            if (Request["t"] != null) 
            {
                string txtString = HttpUtility.UrlDecode(Request["t"]);
                txt01.Text = txtString.Split(new char[] {';' })[0];
                txt02.Text = txtString.Split(new char[] { ';' })[1];
            }
        }
    }

    private void SetCheckBox(string c, CheckBox ckb)
    {
        if (c == "1") { ckb.Checked = true; } else { ckb.Checked = false; }
    }
}
